package com.crm.common.crm.entity.PO;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * <p>
 * 回款表
 * </p>
 *
 * @author zhangzhiwei
 * @since 2020-05-28
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("bill_crm_receivables")
@ApiModel(value="CrmReceivables对象", description="回款表")
public class CrmReceivables implements Serializable {

    private static final long serialVersionUID=1L;


    private Integer studentId;

    @ApiModelProperty(value = "回款ID")
    @TableId(value = "receivables_id", type = IdType.AUTO)
    private Integer receivablesId;

    @ApiModelProperty(value = "回款编号")
    private String number;

    @ApiModelProperty(value = "回款计划ID")
    private Integer planId;

    @ApiModelProperty(value = "客户ID")
    private Integer customerId;

    @ApiModelProperty(value = "合同ID")
    private Integer contractId;

    @ApiModelProperty(value = "0待审核、1通过、2拒绝、3审核中 4:撤回 5 未提交")
    private Integer checkStatus;

    @ApiModelProperty(value = "审核记录ID")
    private Integer examineRecordId;

    @ApiModelProperty(value = "支付方式")
    private String returnType;

    @ApiModelProperty(value = "回款金额")
    private BigDecimal money;

    @ApiModelProperty(value = "应还款金额")
    private BigDecimal repaymentDueMoney;

    @ApiModelProperty(value = "备注")
    private String remark;

    @ApiModelProperty(value = "创建人ID")
    @TableField(fill = FieldFill.INSERT)
    private Long createUserId;

    @ApiModelProperty(value = "负责人ID")
    private Long ownerUserId;

    @ApiModelProperty(value = "创建时间")
    @TableField(fill = FieldFill.INSERT)
    private Date createTime;

    @ApiModelProperty(value = "更新时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Date updateTime;

    @ApiModelProperty(value = "备注")
    private String remarks;

    @ApiModelProperty(value = "批次")
    private String batchId;

    @ApiModelProperty(value = "训练营期数")
    private String trainingPeriods;




    @ApiModelProperty(value = "客户来源")
    private String source;

    @ApiModelProperty(value = "负责人所在部门")
    private String ownerDeptId;

    @ApiModelProperty(value = "是否重复")
    private String isRepetition;

    @ApiModelProperty(value = "营销讲师")
    private Long teacherId;

    @ApiModelProperty(value = "学员电话")
    private String studentsCall;


    @ApiModelProperty(value = "购买课程")
    private String courseSource;



    @ApiModelProperty(value = "人群属性")
    private String crowdAttribute;





    @ApiModelProperty(value = "附件")
    private String enclosure;

    @ApiModelProperty(value = "三方平台合同订单号")
    private String threePartOrderNo;

    @ApiModelProperty(value = "回款类型 1账单回款 2退款补款3全额回款4首付款回款")
    private String collectionType;

    @ApiModelProperty(value = "账单支付方式：知好付")
    private  String billReturnType;

    @ApiModelProperty(value = "回款类别1三方账单2人工创建")
    private String type;

    @ApiModelProperty(value = "学员姓名")
    private String studentName;



    @ApiModelProperty(value = "期数")
    private  Integer periodsNum;

    @ApiModelProperty(value = "第几期")
    private Integer repayPeriods;

    @ApiModelProperty(value = "手续费")
    private BigDecimal commissionMoney;

    @ApiModelProperty(value = "逾期时间")
    private Date overdueTime;

    @ApiModelProperty(value = "应还款时间")
    private Date repaymentDueDate;

    @ApiModelProperty(value = "实际还款时间")
    private Date actualRepaymentDate;

    @ApiModelProperty(value = "付款日期")
    private Date paymentTime;

    @ApiModelProperty(value = "审核通过时间")
    private Date checkTime;

    @ApiModelProperty(value = "所属账单池")
    private String ownerOrderPool;

    @ApiModelProperty(value = "还款状态还款中 已还清 已逾期 已退学 已作废")
    private String repaymentStatus;

    /**
     * 有效，过期
     */
    private String orderPoolStatus;

    @ApiModelProperty(value = "获取表单时间")
    private Date leadsFormTime;

    @ApiModelProperty("入学状态")
    private String studentStatus;


}
